﻿package classes
{

	public class sale
	{

		var myXMLURL:URLRequest = new URLRequest("res/sale.xml");
		s_Loader = new URLLoader(myXMLURL);
		//注册数据读取完成函数
		s_Loader.addEventListener("complete",xmlLoaded);

		public function xmlLoaded(event:Event):void
		{
			var myXML:XML = new XML(s_Loader.data);
			s_ItemCount = myXML.itemCount;//获取商店道具数量
			s_aCells = new Array();
			for (var item:int = 0; item < ItemCount; item ++)
			{
				var itemCells:Array = new Array();
				s_aCells.push(itemCells);
				this.addChild(cell);
				var id:int = myXML.count[count];
				cell.setID(id);
			}
			s_bLoaded = true;
		}
	}
}